<%= form_for(@message, :html => {:id => "add-form"}) do |f| %>
  <% if @message.errors.any? %>
    <div class="message error_message">
      <h2><%= pluralize(@message.errors.count, "error") %> prohibited this message from being saved:</h2>

      <ul>
      <% @message.errors.full_messages.each do |msg| %>
        <li><%= msg %></li>
      <% end %>
      </ul>
    </div>
  <% end %>
<a href="#" id="close">x</a>
    <%= f.label :title %>
    <%= f.text_field :title %>
    <%= f.label :content %>
    <%= f.text_area :content %>
    <%= f.hidden_field :sender_id %>
    <%= f.hidden_field :receiver_id %>
  <div class="actions">
    <%= f.submit %>
  </div>
<% end %>
